import java.util.Arrays;

public class Demo04 {
    public static void main(String[] args){
        Group group = new Group();
        group.setNames("张三", "李四", "王五");
        System.out.println(group.getNames());
    }
}


class Group{
    private String[] names;

    public void setNames(String... names){
        this.names = names;
    }

    public String getNames(){
        return Arrays.toString(names);
    }
}
